﻿<?xml version="1.0" encoding="utf-8"?>
<xs:schema attributeFormDefault="unqualified" elementFormDefault="qualified" targetNamespace="http://tempuri.org/siteconfigurator.xsd" xmlns="http://tempuri.org/siteconfigurator.xsd" xmlns:xs="http://www.w3.org/2001/XMLSchema">
	<xs:group name="WebConfigurationMethods" >
		<xs:sequence>
			<xs:choice maxOccurs="unbounded">
				<xs:element name="SiteGroup">
					<xs:complexType>
						<xs:attribute name="Name" type="xs:string" use="required" />
						<xs:attribute name="Role" type="xs:string" use="required" />
						<xs:attribute name="Owner" type="xs:string" use="required" />
						<xs:attribute name="DefaultUser" type="xs:string" use="required" />
						<xs:attribute name="AddSiteTitleToNames" type="xs:string" use="required" />
						<xs:attribute name="RenameGroupTo" type="xs:string" use="optional" />
						<xs:attribute name="AllowMembersEditMembership" type="xs:string" use="optional" />
						<xs:attribute name="OnlyAllowMembersViewMembership" type="xs:string" use="optional" />
						<xs:attribute name="AllowRequestToJoinLeave" type="xs:string" use="optional" />
						<xs:attribute name="AutoAcceptRequestToJoinLeave" type="xs:string" use="optional" />
						<xs:attribute name="RequestToJoinLeaveEmailSetting" type="xs:string" use="optional" />
						<xs:attribute name="AssociatedGroups" type="xs:boolean" use="optional" />
					</xs:complexType>
				</xs:element>
				<xs:element name="RoleDefinitionToUpdate">
					<xs:complexType>
						<xs:sequence>
							<xs:element maxOccurs="unbounded" name="Permission">
								<xs:complexType>
									<xs:simpleContent>
										<xs:extension base="xs:string">
											<xs:attribute name="Name" type="xs:string" use="required" />
										</xs:extension>
									</xs:simpleContent>
								</xs:complexType>
							</xs:element>
						</xs:sequence>
						<xs:attribute name="Name" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element maxOccurs="unbounded" name="RegionalSetting">
					<xs:complexType>
						<xs:attribute name="Name" type="xs:string" use="required" />
						<xs:attribute name="Value" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="ApplyTheme">
					<xs:complexType>
						<xs:attribute name="Id" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="FileToProvision">
					<xs:complexType>
						<xs:attribute name="FileName" type="xs:string" use="required" />
						<xs:attribute name="NavBarHome" type="xs:string" use="required" />
						<xs:attribute name="Folder" type="xs:string" use="optional" />
					</xs:complexType>
				</xs:element>
				<xs:element maxOccurs="unbounded" name="WebProperty">
					<xs:complexType>
						<xs:attribute name="Name" type="xs:string" use="required" />
						<xs:attribute name="Value" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="AvailableWebTemplates">
					<xs:complexType>
						<xs:attribute name="TemplateList" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="AddWebTemplates">
					<xs:complexType>
						<xs:attribute name="TemplateList" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="RemoveWebTemplates">
					<xs:complexType>
						<xs:attribute name="TemplateList" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element maxOccurs="unbounded" name="TopNavigationLink">
					<xs:complexType>
						<xs:attribute name="Title" type="xs:string" use="required" />
						<xs:attribute name="Link" type="xs:string" use="required" />
						<xs:attribute name="IsExternal" type="xs:boolean" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element maxOccurs="unbounded" name="TopNavigationToDelete">
					<xs:complexType>
						<xs:attribute name="Title" type="xs:string" use="required" />
						<xs:attribute name="Link" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="RoleInheritance">
					<xs:complexType>
						<xs:attribute name="Value" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="DefaultAssociatedGroups">
					<xs:complexType>
						<xs:attribute name="userlogin" type="xs:string" use="required" />
						<xs:attribute name="userlogin2" type="xs:string" use="required" />
						<xs:attribute name="groupNameSeed" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="DeleteSiteGroup">
					<xs:complexType>
						<xs:attribute name="Name" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="DeleteWebPart">
					<xs:complexType>
						<xs:attribute name="WebPartTitle" type="xs:string" use="required" />
						<xs:attribute name="FileName" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="RenameWebPart">
					<xs:complexType>
						<xs:attribute name="WebPartTitle" type="xs:string" use="required" />
						<xs:attribute name="WebPartRenameTo" type="xs:string" use="required" />
						<xs:attribute name="FileName" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element maxOccurs="unbounded" name="AddUserToGroup">
					<xs:complexType>
						<xs:attribute name="GroupName" type="xs:string" use="required" />
						<xs:attribute name="Users" type="xs:string" use="required" />
						<xs:attribute name="AddSiteTitleToGroupNames" type="xs:string" use="optional" />
						<xs:attribute name="SubWebOnly" type="xs:string" use="optional" />
					</xs:complexType>
				</xs:element>
				<xs:element maxOccurs="unbounded" name="AddUserToGroupFromGroup">
					<xs:complexType>
						<xs:attribute name="GroupName" type="xs:string" use="required" />
						<xs:attribute name="FromGroupName" type="xs:string" use="required" />
						<xs:attribute name="AddSiteTitleToGroupNames" type="xs:string" use="optional" />
					</xs:complexType>
				</xs:element>
				<xs:element name="DeleteQuickLaunchHeading">
					<xs:complexType>
						<xs:attribute name="Title" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="DeleteExplicitTopNavigationLinks">
					<xs:complexType>
						<xs:attribute name="Link" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="DeleteQuickLaunchLinks" />
				<xs:element maxOccurs="unbounded" name="QuickLaunchHeading">
					<xs:complexType>
						<xs:attribute name="Title" type="xs:string" use="required" />
						<xs:attribute name="Link" type="xs:string" use="required" />
						<xs:attribute name="IsExternal" type="xs:boolean" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="DeleteQuickLaunchLinkItem" maxOccurs="unbounded" >
					<xs:complexType>
						<xs:attribute name="Heading" type="xs:string" use="required" />
						<xs:attribute name="Title" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element maxOccurs="unbounded" name="QuickLaunchLink">
					<xs:complexType>
						<xs:attribute name="Title" type="xs:string" use="required" />
						<xs:attribute name="Heading" type="xs:string" use="required" />
						<xs:attribute name="Link" type="xs:string" use="required" />
						<xs:attribute name="IsExternal" type="xs:boolean" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element maxOccurs="unbounded" name="PropertyBag">
					<xs:complexType>
						<xs:attribute name="Name" type="xs:string" use="required" />
						<xs:attribute name="Value" type="xs:string" use="required" />
						<xs:attribute name="AllowWebConfigOverride" type="xs:boolean" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element maxOccurs="unbounded" name="AllPropertyBag">
					<xs:complexType>
						<xs:attribute name="Name" type="xs:string" use="required" />
						<xs:attribute name="Value" type="xs:string" use="required" />
						<xs:attribute name="AllowWebConfigOverride" type="xs:boolean" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element maxOccurs="unbounded" name="WebFeature">
					<xs:complexType>
						<xs:attribute name="Guid" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="ListInstance">
					<xs:complexType>
						<xs:attribute name="Title" type="xs:string" use="required" />
						<xs:attribute name="Type" type="xs:string" use="required" />
						<xs:attribute name="Description" type="xs:string" use="required" />
						<xs:attribute name="EnableAttachments" type="xs:boolean" use="optional" />
						<xs:attribute name="IsCustomListTemplate" type="xs:boolean" use="optional" />
					</xs:complexType>
				</xs:element>
				<xs:element name="ListViewWebPart">
					<xs:complexType>
						<xs:sequence>
							<xs:element minOccurs="0" maxOccurs="1" name="ViewQuery" />
						</xs:sequence>
						<xs:attribute name="FileName" type="xs:string" use="optional" />
						<xs:attribute name="Title" type="xs:string" use="required" />
						<xs:attribute name="ListName" type="xs:string" use="required" />
						<xs:attribute name="ViewName" type="xs:string" use="required" />
						<xs:attribute name="ZoneID" type="xs:string" use="required" />
						<xs:attribute name="ZoneIndex" type="xs:unsignedByte" use="required" />
						<xs:attribute name="ToolbarType" type="xs:string" use="required" />
						<xs:attribute name="AllowMinimize" type="xs:boolean" use="required" />
						<xs:attribute name="AllowClose" type="xs:boolean" use="required" />
						<xs:attribute name="AllowHide" type="xs:boolean" use="required" />
						<xs:attribute name="AllowZoneChange" type="xs:boolean" use="required" />
						<xs:attribute name="AllowConnect" type="xs:boolean" use="required" />
						<xs:attribute name="AllowEdit" type="xs:boolean" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="ContentTypeBinding">
					<xs:complexType>
						<xs:attribute name="ContentTypeId" type="xs:string" use="required" />
						<xs:attribute name="ListUrl" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="AllUsersWebPart">
					<xs:complexType>
						<xs:simpleContent>
							<xs:extension base="xs:string">
								<xs:attribute name="WebPartZoneID" type="xs:string" use="required" />
								<xs:attribute name="WebPartOrder" type="xs:unsignedByte" use="required" />
								<xs:attribute name="FileName" type="xs:string" use="required" />
								<xs:attribute name="AllowConfigOverride" type="xs:boolean" use="optional" />
								<xs:attribute name="AllowConfigOverrideIdentifier" type="xs:string" use="optional" />
								<xs:attribute name="ViewName" type="xs:string" use="optional" />
								<xs:attribute name="WebPartType" type="xs:string" use="optional" />
								<xs:attribute name="ReplaceTokens" type="xs:boolean" use="optional" />
							</xs:extension>
						</xs:simpleContent>
					</xs:complexType>
				</xs:element>
				<xs:element name="Views">
					<xs:complexType>
						<xs:simpleContent>
							<xs:extension base="xs:string">
								<xs:attribute name="ListTitle" type="xs:string" use="required"/>
							</xs:extension>
						</xs:simpleContent>
					</xs:complexType>
				</xs:element>
				<xs:element name="CustomListField">
					<xs:complexType>
						<xs:simpleContent>
							<xs:extension base="xs:string">
								<xs:attribute name="ListTitle" type="xs:string" use="required"/>
							</xs:extension>
						</xs:simpleContent>
					</xs:complexType>
				</xs:element>
				<xs:element name="IrmSettings">
					<xs:complexType>
						<xs:attribute name="ListInstance" type="xs:string" use="required" />
						<xs:attribute name="IrmEnabled" type="xs:boolean" use="required" />
						<xs:attribute name="IrmTitle" type="xs:string" use="required" />
						<xs:attribute name="IrmDescription" type="xs:string" use="required" />
						<xs:attribute name="IrmPrint" type="xs:boolean" use="required" />
						<xs:attribute name="IrmVBA" type="xs:boolean" use="required" />
						<xs:attribute name="IrmOffline" type="xs:boolean" use="required" />
						<xs:attribute name="IrmOfflineDays" type="xs:unsignedByte" use="required" />
						<xs:attribute name="IrmReject" type="xs:boolean" use="required" />
						<xs:attribute name="IrmExpire" type="xs:boolean" use="required" />
						<xs:attribute name="IrmExpireDate" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="ContentTypeInformationManagementPolicy">
					<xs:complexType>
						<xs:sequence>
							<xs:element name="PolicyItems">
								<xs:complexType>
									<xs:sequence>
										<xs:element name="PolicyItem">
											<xs:complexType>
												<xs:sequence>
													<xs:element name="CustomData">
														<xs:complexType>
															<xs:sequence>
																<xs:element name="data">
																	<xs:complexType>
																		<xs:sequence>
																			<xs:element name="formula">
																				<xs:complexType>
																					<xs:sequence>
																						<xs:element name="number" type="xs:unsignedByte" />
																						<xs:element name="property" type="xs:string" />
																						<xs:element name="period" type="xs:string" />
																					</xs:sequence>
																					<xs:attribute name="id" type="xs:string" use="required" />
																				</xs:complexType>
																			</xs:element>
																			<xs:element name="action">
																				<xs:complexType>
																					<xs:attribute name="type" type="xs:string" use="required" />
																					<xs:attribute name="id" type="xs:string" use="required" />
																				</xs:complexType>
																			</xs:element>
																		</xs:sequence>
																	</xs:complexType>
																</xs:element>
															</xs:sequence>
														</xs:complexType>
													</xs:element>
												</xs:sequence>
												<xs:attribute name="FeatureId" type="xs:string" use="required" />
											</xs:complexType>
										</xs:element>
									</xs:sequence>
								</xs:complexType>
							</xs:element>
						</xs:sequence>
						<xs:attribute name="Name" type="xs:string" use="required" />
						<xs:attribute name="ContentTypeId" type="xs:string" use="required" />
						<xs:attribute name="Description" type="xs:string" use="required" />
						<xs:attribute name="Statement" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="DeleteListInstance">
					<xs:complexType>
						<xs:attribute name="Title" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="RoleDefinitionToDelete">
					<xs:complexType>
						<xs:attribute name="Name" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="RoleDefinition">
					<xs:complexType>
						<xs:sequence>
							<xs:element maxOccurs="unbounded" name="Permission">
								<xs:complexType>
									<xs:simpleContent>
										<xs:extension base="xs:string">
											<xs:attribute name="Name" type="xs:string" use="required" />
										</xs:extension>
									</xs:simpleContent>
								</xs:complexType>
							</xs:element>
						</xs:sequence>
						<xs:attribute name="Name" type="xs:string" use="required" />
						<xs:attribute name="Description" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="CreateDefaultAssociatedGroups">
					<xs:complexType>
						<xs:attribute name="userlogin" type="xs:string" use="required" />
						<xs:attribute name="userlogin2" type="xs:string" use="required" />
						<xs:attribute name="groupNameSeed" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="PublishingNavigation">
					<xs:complexType>
						<xs:attribute name="inheritTopNavRadioButton" type="xs:boolean" use="optional" />
						<xs:attribute name="GlobalIncludePages" type="xs:boolean" use="optional" />
						<xs:attribute name="GlobalIncludeSubSites" type="xs:boolean" use="optional" />
						<xs:attribute name="InheritCurrent" type="xs:boolean" use="optional" />
						<xs:attribute name="ShowSiblings" type="xs:boolean" use="optional" />
						<xs:attribute name="CurrentIncludePages" type="xs:boolean" use="optional" />
						<xs:attribute name="CurrentIncludeSubSites" type="xs:string" use="optional" />
						<xs:attribute name="OrderingMethod" type="xs:string" use="optional" />
						<xs:attribute name="AutomaticSortingMethod" type="xs:string" use="optional" />
						<xs:attribute name="SortAscending" type="xs:string" use="optional" />
					</xs:complexType>
				</xs:element>
				<xs:element name="CreateSubSite" maxOccurs="unbounded">
					<xs:complexType>
						<xs:sequence>
							<xs:choice maxOccurs="unbounded" minOccurs="0">
								<xs:group ref="WebConfigurationMethods" />
							</xs:choice>
						</xs:sequence>
						<xs:attribute name="Url" type="xs:string" use="required" />
						<xs:attribute name="Title" type="xs:string" use="required" />
						<xs:attribute name="Description" type="xs:string" use="required" />
						<xs:attribute name="Template" type="xs:string" use="required" />
						<xs:attribute name="UseUniquePermissions" type="xs:boolean" use="required" />
						<xs:attribute name="UseSharedNavigation" type="xs:boolean" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="MasterPageUrl">
					<xs:complexType>
						<xs:attribute name="Url" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="SecurityGroupQuickLaunch">
					<xs:complexType>
						<xs:attribute name="KeepExisting" type="xs:boolean" use="required" />
						<xs:attribute name="Groups" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
			</xs:choice>
		</xs:sequence>
	</xs:group>
	<xs:group name="SiteConfigurationMethods">

		<xs:sequence>
			
			<xs:choice maxOccurs="unbounded">
				
				<xs:element name="SetSiteCollectionAdministrators" maxOccurs="1">
					<xs:complexType>
						<xs:attribute name="Users" type="xs:string" use="required" />
						<xs:attribute name="AllowWebConfigOverride" type="xs:boolean" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element maxOccurs="unbounded" name="SiteCollectionFeature">
					<xs:complexType>
						<xs:attribute name="Guid" type="xs:string" use="required" />
						<xs:attribute name="Scope" type="featureScope" use="optional"  />	
					</xs:complexType>
				</xs:element>
				<xs:element name="SiteCollectionInformationManagementPolicy">
					<xs:complexType>
						<xs:sequence>
							<xs:element name="PolicyManifest">
								<xs:complexType>
									<xs:sequence>
										<xs:element name="Policy">
											<xs:complexType>
												<xs:sequence>
													<xs:element name="Name" type="xs:string" />
													<xs:element name="Description" type="xs:string" />
													<xs:element name="Statement" type="xs:string" />
													<xs:element name="PolicyItems">
														<xs:complexType>
															<xs:sequence>
																<xs:element name="PolicyItem">
																	<xs:complexType>
																		<xs:sequence>
																			<xs:element name="Name" type="xs:string" />
																			<xs:element name="Description" type="xs:string" />
																			<xs:element name="CustomData">
																				<xs:complexType>
																					<xs:sequence>
																						<xs:element name="data">
																							<xs:complexType>
																								<xs:sequence>
																									<xs:element name="formula">
																										<xs:complexType>
																											<xs:sequence>
																												<xs:element name="number" type="xs:unsignedByte" />
																												<xs:element name="property" type="xs:string" />
																												<xs:element name="period" type="xs:string" />
																											</xs:sequence>
																											<xs:attribute name="id" type="xs:string" use="required" />
																										</xs:complexType>
																									</xs:element>
																									<xs:element name="action">
																										<xs:complexType>
																											<xs:attribute name="type" type="xs:string" use="required" />
																											<xs:attribute name="id" type="xs:string" use="required" />
																										</xs:complexType>
																									</xs:element>
																								</xs:sequence>
																							</xs:complexType>
																						</xs:element>
																					</xs:sequence>
																				</xs:complexType>
																			</xs:element>
																		</xs:sequence>
																		<xs:attribute name="featureId" type="xs:string" use="required" />
																	</xs:complexType>
																</xs:element>
															</xs:sequence>
														</xs:complexType>
													</xs:element>
												</xs:sequence>
												<xs:attribute name="local" type="xs:boolean" use="required" />
												<xs:attribute name="id" type="xs:string" use="required" />
											</xs:complexType>
										</xs:element>
									</xs:sequence>
								</xs:complexType>
							</xs:element>
						</xs:sequence>
						<xs:attribute name="Id" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="SiteCollectionInformationManagementPolicyContentTypeAssociation">
					<xs:complexType>
						<xs:attribute name="ContentTypeId" type="xs:string" use="required" />
						<xs:attribute name="PolicyId" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
				<xs:element name="ApplyTheme2010">
					<xs:complexType>
						<xs:attribute name="Id" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
			</xs:choice>
		</xs:sequence>
	</xs:group>
	<xs:element name="SiteConfigurations">
		<xs:complexType>
			<xs:sequence>
				<xs:element maxOccurs="unbounded" name="SiteConfiguration">
					<xs:complexType>
						<xs:sequence>
							<xs:choice maxOccurs="unbounded">
								<xs:element name="ConfigureSubSite" maxOccurs="unbounded">
									<xs:complexType>
										<xs:sequence>
											<xs:choice maxOccurs="unbounded">
												<xs:group ref="WebConfigurationMethods" />
											</xs:choice>
										</xs:sequence>
										<xs:attribute name="Url" type="xs:string" use="required" />
									</xs:complexType>
								</xs:element>
								<xs:group ref="SiteConfigurationMethods" />
								<xs:group ref="WebConfigurationMethods" />
							</xs:choice>
						</xs:sequence>
						<xs:attribute name="Name" type="xs:string" use="required" />
					</xs:complexType>
				</xs:element>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<xs:simpleType name="featureScope">
		<xs:restriction base="xs:string">
			<xs:enumeration value="Site" />
			<xs:enumeration value="Farm" />
		</xs:restriction>
	</xs:simpleType>
</xs:schema>